package com.zhiyi.coco.service.impl;

import com.zhiyi.coco.dao.TemperatureMapper;
import com.zhiyi.coco.entity.Temperature;
import com.zhiyi.coco.service.TemperatureService;
import lombok.extern.log4j.Log4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

@Service
@Transactional
@Log4j
public class TemperatureServiceImpl implements TemperatureService {
    @Autowired
    private TemperatureMapper mapper;

    @Override
    public List<Temperature> getAll(Integer fId) {
        return mapper.getAll(fId);
    }

    @Override
    public Integer deleteByfId(Integer fId) {
        return mapper.deleteByfId(fId);
    }

    @Override
    public Integer insertSelective(Temperature temperature) {
        return mapper.insertSelective(temperature);
    }
}
